import time
import functools


def start(fun):
    @functools.wraps(fun)
    def wrapper(*args, **kw):
        t1 = time.time()
        fun(*args, **kw)
        t2 = time.time()
        print('执行时间：%s' % (t2 - t1))

        return fun(*args, **kw)

    return wrapper


@start
def print1():
    print('....')
    time.sleep(0.05)


print1()


@start
def fast(x, y):
    time.sleep(0.0012)
    return x + y


fast(1,2)
